package com.simple.mq.test.consumer;

import com.alibaba.fastjson.JSON;
import com.simple.mq.boot.starter.annotation.MqConsumer;
import com.simple.mq.boot.starter.service.SimpleMqConsumerService;

/**
 * 项目: simple-mq
 *
 * 功能描述:
 *
 * @author: WuChengXing
 *
 * @create: 2023-09-22 15:31
 **/
@MqConsumer(queueNames = {"springQueue"}, clientName = "Test SpringQueue Consumer")
public class SpringQueueConsumer implements SimpleMqConsumerService {

    @Override
    public void consumer(String queueName, Object message) {
        System.out.println("Spring 消费：" + queueName + " ==> " + JSON.toJSONString(message));
    }
}
